package com.ruoyi.huanghefd.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

/**
 * 热机检修工作停送电联系单
 * @TableName contactsheet_rj
 */
@TableName(value ="contactsheet_rj")
@Data
public class ContactsheetRj implements Serializable {
    /**
     * ID
     */
    private String cnId;

    /**
     * 联系单编号
     */
    private String cnCode;

    /**
     * 联系单类型，0-热机检修工作停电联系单,1-热机检修工作送电联系单
     */
    private String cnType;

    /**
     * 联系单状态；待商定
     */
    private Integer cnState;

    /**
     * 工作票编号
     */
    private String wsCode;

    /**
     * 值班负责人ID
     */
    private String dutyPrincipalid;

    /**
     * 值班负责人
     */
    private String dutyPrincipal;

    /**
     * 停送电设备名称
     */
    private String poweroffonDev;

    /**
     * 热机申请人ID
     */
    private String rjProposerid;

    /**
     * 热机申请人
     */
    private String rjProposer;

    /**
     * 电气接受人ID
     */
    private String dqReceiverid;

    /**
     * 电气接受人
     */
    private String dqReceiver;

    /**
     * 申请停送电时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date applyStarttime;

    /**
     * 停送电完成时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date applyEndtime;

    /**
     * 停送电措施执行人id
     */
    private String executorid;

    /**
     * 停送电措施执行人
     */
    private String executor;

    /**
     * 已已通知热机负责人id
     */
    private String noticePrincipalid;

    /**
     * 已已通知热机负责人
     */
    private String noticePrincipal;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        ContactsheetRj other = (ContactsheetRj) that;
        return (this.getCnId() == null ? other.getCnId() == null : this.getCnId().equals(other.getCnId()))
            && (this.getCnCode() == null ? other.getCnCode() == null : this.getCnCode().equals(other.getCnCode()))
            && (this.getCnType() == null ? other.getCnType() == null : this.getCnType().equals(other.getCnType()))
            && (this.getCnState() == null ? other.getCnState() == null : this.getCnState().equals(other.getCnState()))
            && (this.getWsCode() == null ? other.getWsCode() == null : this.getWsCode().equals(other.getWsCode()))
            && (this.getDutyPrincipalid() == null ? other.getDutyPrincipalid() == null : this.getDutyPrincipalid().equals(other.getDutyPrincipalid()))
            && (this.getDutyPrincipal() == null ? other.getDutyPrincipal() == null : this.getDutyPrincipal().equals(other.getDutyPrincipal()))
            && (this.getPoweroffonDev() == null ? other.getPoweroffonDev() == null : this.getPoweroffonDev().equals(other.getPoweroffonDev()))
            && (this.getRjProposerid() == null ? other.getRjProposerid() == null : this.getRjProposerid().equals(other.getRjProposerid()))
            && (this.getRjProposer() == null ? other.getRjProposer() == null : this.getRjProposer().equals(other.getRjProposer()))
            && (this.getDqReceiverid() == null ? other.getDqReceiverid() == null : this.getDqReceiverid().equals(other.getDqReceiverid()))
            && (this.getDqReceiver() == null ? other.getDqReceiver() == null : this.getDqReceiver().equals(other.getDqReceiver()))
            && (this.getApplyStarttime() == null ? other.getApplyStarttime() == null : this.getApplyStarttime().equals(other.getApplyStarttime()))
            && (this.getApplyEndtime() == null ? other.getApplyEndtime() == null : this.getApplyEndtime().equals(other.getApplyEndtime()))
            && (this.getExecutorid() == null ? other.getExecutorid() == null : this.getExecutorid().equals(other.getExecutorid()))
            && (this.getExecutor() == null ? other.getExecutor() == null : this.getExecutor().equals(other.getExecutor()))
            && (this.getNoticePrincipalid() == null ? other.getNoticePrincipalid() == null : this.getNoticePrincipalid().equals(other.getNoticePrincipalid()))
            && (this.getNoticePrincipal() == null ? other.getNoticePrincipal() == null : this.getNoticePrincipal().equals(other.getNoticePrincipal()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getCnId() == null) ? 0 : getCnId().hashCode());
        result = prime * result + ((getCnCode() == null) ? 0 : getCnCode().hashCode());
        result = prime * result + ((getCnType() == null) ? 0 : getCnType().hashCode());
        result = prime * result + ((getCnState() == null) ? 0 : getCnState().hashCode());
        result = prime * result + ((getWsCode() == null) ? 0 : getWsCode().hashCode());
        result = prime * result + ((getDutyPrincipalid() == null) ? 0 : getDutyPrincipalid().hashCode());
        result = prime * result + ((getDutyPrincipal() == null) ? 0 : getDutyPrincipal().hashCode());
        result = prime * result + ((getPoweroffonDev() == null) ? 0 : getPoweroffonDev().hashCode());
        result = prime * result + ((getRjProposerid() == null) ? 0 : getRjProposerid().hashCode());
        result = prime * result + ((getRjProposer() == null) ? 0 : getRjProposer().hashCode());
        result = prime * result + ((getDqReceiverid() == null) ? 0 : getDqReceiverid().hashCode());
        result = prime * result + ((getDqReceiver() == null) ? 0 : getDqReceiver().hashCode());
        result = prime * result + ((getApplyStarttime() == null) ? 0 : getApplyStarttime().hashCode());
        result = prime * result + ((getApplyEndtime() == null) ? 0 : getApplyEndtime().hashCode());
        result = prime * result + ((getExecutorid() == null) ? 0 : getExecutorid().hashCode());
        result = prime * result + ((getExecutor() == null) ? 0 : getExecutor().hashCode());
        result = prime * result + ((getNoticePrincipalid() == null) ? 0 : getNoticePrincipalid().hashCode());
        result = prime * result + ((getNoticePrincipal() == null) ? 0 : getNoticePrincipal().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", cnId=").append(cnId);
        sb.append(", cnCode=").append(cnCode);
        sb.append(", cnType=").append(cnType);
        sb.append(", cnState=").append(cnState);
        sb.append(", wsCode=").append(wsCode);
        sb.append(", dutyPrincipalid=").append(dutyPrincipalid);
        sb.append(", dutyPrincipal=").append(dutyPrincipal);
        sb.append(", poweroffonDev=").append(poweroffonDev);
        sb.append(", rjProposerid=").append(rjProposerid);
        sb.append(", rjProposer=").append(rjProposer);
        sb.append(", dqReceiverid=").append(dqReceiverid);
        sb.append(", dqReceiver=").append(dqReceiver);
        sb.append(", applyStarttime=").append(applyStarttime);
        sb.append(", applyEndtime=").append(applyEndtime);
        sb.append(", executorid=").append(executorid);
        sb.append(", executor=").append(executor);
        sb.append(", noticePrincipalid=").append(noticePrincipalid);
        sb.append(", noticePrincipal=").append(noticePrincipal);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}